In recent years, along with the popularization of personal computers, it has become easy to input an image using an image input device such as a digital camera, color scanner, or the like, to display and confirm that image using an image display device such as a CRT, LCD, or the like, and to output the image via an image output device such as a color printer or the like. In this case, in order to correct any color appearance difference due to the difference between color gamuts of the display and output devices, a color matching process (gamut mapping) is normally executed. That is, the color appearance difference between the devices is compensated for by the color matching process.
One such color matching process is a method using an ICC profile. Note that the ICC profile is a profile based on a format defined by the International Color Consortium.
As shown in FIG. 1, the process using an ICC profile converts the RGB values of an image obtained by the input device into CIEXYZ or CIEL*a*b* values as a device-independent color space using a source profile, and converts the CIEXYZ or CIEL*a*b* values into the device RGB values of the output (display) device using a destination profile. The source profile describes an RGB to XYZ conversion matrix or an RGB to Lab conversion lookup table (LUT) that represents the color reproduction character of the input device. On the other hand, the destination profile describes a Lab to device RGB LUT according to a specific format. The LUT of this destination profile has the following format. That is, grid point data obtained by evenly n-slicing (where n is an integer, and where the term “n-slicing” denotes that a region is divided into n−1 slices) an L* value region 0<L*<100, an a* value region −128<a*<127, and a b* value region −128<b*<127 are defined, and the LUT describes device RGB values obtained by mapping these L*a*b* values onto the color gamut of the output device.
In this manner, in the processing system of the ICC profile, color matching information, i.e., gamut mapping information, is described in the LUT in the destination profile together with color gamut information of the output device.
On the other hand, a color appearance model that models the human visual sense with higher precision than the conventional CIELAB color space has been announced. The color values (e.g., J*a*b* values) of this color appearance space can be calculated from CIEXYZ values. By performing gamut mapping using these J*a*b* values, color matching more suited to the human visual sense can be achieved.
When an estimation of color matching using the color appearance space realized by the processing system of the ICC profile is made, a new destination profile must be generated from a destination profile of the ICC profile. Note that this generation method is the subject matter of the present invention, which is described below, but a brief description is also provided here to provide the reader with a clearer understanding of the purpose and use of the invention.
The destination profile is embedded with the LUT in the predetermined format that describes the relationship between the L*a*b* values and RGB values (DevRGB). In other words, in order to convert color matching information using the color appearance space into a destination profile, the following processes are required: (i) the L*a*b* grid points in the predetermined format are converted into J*a*b* values using color appearance conversion formulas, (ii) the J*a*b* values are mapped into the color gamut of the output device, (iii) the mapped J*a*b* values are converted into the device RGB, and (iv) the device RGB values are stored in an LUT. The flow of calculations can be denoted as L*a*b*→J*a*b*→J*′a*′b*′→DevRGB, as shown in FIG. 2.
However, the conversion formula required to obtain the color values J*a*b* of the color appearance space does not support colors outside of the visible region. In the color appearance conversion, for example, color adaptation conversion, cone response conversion, or opponent-colors response conversion is made so the color values approximate the human visible sense. The conversion method of the color adaptation conversion is a linear conversion represented by a matrix conversion given by:
                              A          ′                =                              (                                                                                a                    00                                                                                        a                    01                                                                                        a                    02                                                                                                                    a                    10                                                                                        a                    11                                                                                        a                    12                                                                                                                    a                    20                                                                                        a                    21                                                                                        a                    22                                                                        )                    ⁢                                          ⁢          A                                    (        1        )            The cone response conversion also involves performing, in addition to the matrix conversion, an exponentiation given by:
                              A          ′                =                                            b              ⁢                                                          ⁢                                                (                                      cA                    /                    d                                    )                                e                                                    f              +                                                (                                      cA                    /                    d                                    )                                e                                              +          g                                    (        2        )            where a00 to a22, and b to g are constants (for 0≦e≦1), A is a value before conversion, and A′ is a value after conversion.
The opponent-colors response conversion converts the values after cone response conversion into coordinate J*a*b* values suited to the human visualsense, and linear conversion and triangular function conversion are used as representative conversion formulas for that purpose.
According to these conversion formulas, when XYZ values indicating a color outside of the visible region are input, the color adaptation conversion (equation (1)) can be calculated, but calculation errors may occur when the exponentiation, such as that in equation (2), is calculated. This is for the following reason. That is, the constants in equations (1) and (2) are set so that (cA/d) in equation (2) assumes a positive value in the case of a color within the visible region. However, (cA/d) often assumes a negative value when a color outside of the visible region is input, and this disables the calculations.
More specifically, as shown in FIG. 3, of the L*a*b* grid points defined on the CIELAB space, a color (e.g., L*=0, a*=−128, b*=−128) outside of the visible region cannot be converted into J*a*b* values, and device RGB values corresponding to that grid point cannot be calculated. In practice, when color matching is done by the processing system of the ICC profile, it is impossible for an input image to include a color outside of the visible region, but a color in proximity to a boundary of the visible region often exists in an input image. In order to interpolate such a color using an LUT, since not only grid points within the visible region but also ones outside of the visible region are used for the interpolation, appropriate device RGB values must be set for grid points outside of the visible region.
As a color matching method using the ICC profile and color appearance space, a technique disclosed in Japanese Patent Laid-Open No. 2000-40140 (U.S. application Ser. No. 09/358,407, filed on Jul. 22, 1999, now U.S. Pat. No. 7,027,067) has been proposed. However, the method disclosed in this reference is different from the method described in FIG. 2. The technique disclosed in this reference loads the color gamuts of respective devices from the source profile and destination profile described in the ICC profile format into a dedicated apparatus, and attains gamut mapping by converting the respective color gamuts into J*a*b* values using a CIECAM97 conversion formula as one of the known color appearance conversion formulas. When this technique is used, a new destination profile that records gamut mapping information on the J*a*b* space need not be generated, and the same profiles as the conventional ones need only be used. Hence, no problems are caused by impossibility of color conversion as described above. However, since this technique requires a special apparatus for color matching, it cannot be used in a general image manipulation application such as PhotoShop®. Since color matching is done using the dedicated apparatus, gamut mapping information described in the ICC profile is completely ignored. In the processing system of the ICC profile, it is required to adopt gamut mapping using the color appearance space. Not only when an ICC profile is generated but also when a process is made on the color appearance space, it is inconvenient that colors outside of the visible region are not supported.